package com.kayt.cyberBar.system.business.entity.po;

import com.kayt.cyberBar.common.base.BaseEntity;

import javax.persistence.*;
import java.util.Date;
import java.util.List;

/**
 * Description
 *
 * @author Kevin
 * @since 12/27/2017 17:53
 */
@Entity
@Table(name="s_system_operator")
@NamedQuery(name="SSystemOperator.findAll", query="SELECT b FROM SSystemOperator b")
public class SSystemOperator extends BaseEntity {
    private static final long serialVersionUID = -7276348521617706658L;
    private Long id;
    private String name;
    private String code;
    private String account;
    private String password;
    private String salt;
    private Integer errorTimes;
    private Integer sex;
    private Integer level;
    private String status;
    private String tel;
    private String companyCode;
    private Date lastLogin;
    private Date createTime;
    private Date updateTime;
    private String operatorAccount;
    private List<SSystemRole> systemRoles;

    @Transient
    public List<SSystemRole> getSystemRoles() {
        return systemRoles;
    }

    public void setSystemRoles(List<SSystemRole> systemRoles) {
        this.systemRoles = systemRoles;
    }

    @Id
    @GeneratedValue(strategy=GenerationType.IDENTITY)
    @Column(name="d_id")
    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }
    @Column(name="d_name")
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
    @Column(name="d_level")
    public Integer getLevel() {
        return level;
    }

    public void setLevel(Integer level) {
        this.level = level;
    }

    @Column(name="d_code")
    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }
    @Column(name = "d_status_code")
    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }
    @Column(name="d_account")
    public String getAccount() {
        return account;
    }

    public void setAccount(String account) {
        this.account = account;
    }
    @Column(name="d_password")
    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }
    @Column(name="d_salt")
    public String getSalt() {
        return salt;
    }

    public void setSalt(String salt) {
        this.salt = salt;
    }
    @Column(name="d_error_times")
    public Integer getErrorTimes() {
        return errorTimes;
    }

    public void setErrorTimes(Integer errorTimes) {
        this.errorTimes = errorTimes;
    }
    @Column(name="d_sex")
    public Integer getSex() {
        return sex;
    }

    public void setSex(Integer sex) {
        this.sex = sex;
    }
    @Column(name="d_tel")
    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel;
    }
    @Column(name="d_company_code")
    public String getCompanyCode() {
        return companyCode;
    }

    public void setCompanyCode(String companyCode) {
        this.companyCode = companyCode;
    }
    @Column(name="d_last_login")
    public Date getLastLogin() {
        return lastLogin;
    }

    public void setLastLogin(Date lastLogin) {
        this.lastLogin = lastLogin;
    }
    @Column(name="d_create_time")
    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Column(name="d_update_time")
    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    @Column(name="d_operator_account")
    public String getOperatorAccount() {
        return operatorAccount;
    }

    public void setOperatorAccount(String operatorAccount) {
        this.operatorAccount = operatorAccount;
    }
}
